home *** CD-ROM | disk | FTP | other *** search
- SET procedure self
- SET talk off
- SET color to w/b
- SET bell off
- SET title to [Magellan Image Atlas]
- SET escape on
- ON escape return
-
- DO WHILE .t.
-
- store "1" to pick1
- DO STARTAPP
- DO CASE
-
- CASE PICK1 = "1"
- do MIDRS
-
- CASE PICK1 = '2'
- do NAMES
-
- CASE PICK1 = '3'
- do FEATURES
-
- CASE PICK1 = '4'
- do REGION
-
- CASE PICK1 = '5'
- clear
- set title to [McMax]
- exit
-
- ENDCASE
- ENDDO
- QUIT
-
- PROCEDURE STARTAPP
- clear
- @ 7,27 say "MAGELLAN IMAGE LOCATIONS"
- @ 8,9 TO 15,70
- @ 9,10 say "(1) Find Images by Latitude / Longitude "
- @ 10,10 say "(2) Find Latitude / Longitude / Origin of a Named Feature"
- @ 11,10 say "(3) Find Named Features in a Specific Image"
- @ 12,10 say "(4) Find Named Features in a Specified Region"
- @ 13,10 say "(5) EXIT"
- @ 17,10 get pick1
- Read
- RETURN
-
- PROCEDURE MIDRS
- use midr
- clear
- Store 0 to whval1, whval2
- @ 1,10 say "ENTER LATITUDE (90.0 to -90.0): ";
- get WHVAL1 picture "###.##"
- @ 2,10 say "ENTER LONGITUDE (0.0 to 360.0): ";
- get WHVAL2 picture "###.##"
- read
- if whval1 > 90 .or. whval1 < -90 .or. whval2 > 360 .or. whval2 < 0
- @ 23,5 say "Value of latitude/longitude out of range."
- wait " Press any key to continue."
- return
- endif
- if whval2 = 360
- store 0 to whval2
- endif
- SET FILTER TO UPPERLAT >= WHVAL1 .AND. LOWERLAT <= WHVAL1 .AND. ;
- FARLEFT <= WHVAL2 .AND. FARRIGHT >= WHVAL2
- goto top
- @ 3,10 say " "
- ? space(10) + " MIDR TYPE CDROM"
- ? space(10) + "--------- ---- -------"
- DO WHILE .NOT. EOF()
- ? space(10) + MIDR + " " + TYPE + " " + CDROM
- skip
- ENDDO
- if whval2+360 < 593.19
- SET FILTER TO UPPERLAT >= WHVAL1 .AND. LOWERLAT <= WHVAL1 .AND. ;
- FARLEFT <= (WHVAL2+360) .AND. FARRIGHT >= (WHVAL2+360)
- goto top
- ?
- DO WHILE .NOT. EOF()
- ? space(10) + MIDR + " " + TYPE + " " + CDROM
- skip
- ENDDO
- endif
-
- store 'N' to whval7
- @ 24,5 say "Do you wish to print these results ?: " ;
- get whval7 picture '!'
- read
- if whval7 = 'Y'
- clear
- @ 10,10 say "WAIT, PLEASE."
- set device to print
- @ 5,5 say "Latitude: "
- @ 5,16 say whval1
- @ 6,5 say "Longitude: "
- @ 6,16 say whval2
- @ 7,5 say " "
- SET FILTER TO UPPERLAT >= WHVAL1 .AND. LOWERLAT <= WHVAL1 .AND. ;
- FARLEFT <= WHVAL2 .AND. FARRIGHT >= WHVAL2
- goto top
- disp all MIDR,TYPE,CDROM to print off
- if whval2+360 < 593.19
- SET FILTER TO UPPERLAT >= WHVAL1 .AND. LOWERLAT <= WHVAL1 .AND. ;
- FARLEFT <= (WHVAL2+360) .AND. FARRIGHT >= (WHVAL2+360)
- goto top
- @ prow()+1,5 say " "
- disp all MIDR,TYPE,CDROM to print off
- endif
- eject
- set device to screen
- endif
- RETURN
-
- PROCEDURE NAMES
- use names
- clear
- @ 2,5 say " "
- ? "FEATURES MAY HAVE A UNIQUE LATITUDE / LONGITUDE OR COVER A RANGE."
- ?
- ? "ENTER WHOLE OR PARTIAL NAMES; I.E."
- ? "APHRODITE TERRA or APHRODITE or APHRO or DITE or TERRA"
- ?
- ? "MORE THAN ONE FEATURE MAY BE FOUND (I.E. TERRA)"
- ? "VIEW THEM ONE BY ONE BY CHOOSING Record Back AND Record Forward."
- ? "(Apple-F or Apple-B)"
- ?
- ? "STOP BY CHOOSING Escape. (Apple-.)"
- ?
- store space(15) to whval3
- @ 16,5 say "ENTER FEATURE NAME: " get whval3 picture '!!!!!!!!!!!!!!!'
- read
- store trim(whval3) to whval4
- if whval3 = " "
- return
- endif
- set filter to '&whval4' $ name
- goto top
- clear
- edit
- RETURN
-
- PROCEDURE FEATURES
- use midr index
- clear
- @ 1,5 say " "
- ? "THIS OPTION FINDS THE NAMED FEATURES ON A SPECIFIED MOSAIC."
- ? "FOR EXAMPLE, IF YOU WANT TO ANNOTATE THE FEATURES IN A PARTICULAR"
- ? "IMAGE, THIS OPTION CAN HELP."
- ?
- ? "ALL NAMED FEATURES WHICH OVERLAP OR LIE INSIDE THE SPECIFIED MOSAIC"
- ? "WILL BE FOUND. SOME FEATURES MAY BE LARGER THAN THE MOSAIC, SO"
- ? "THEY WILL NOT BE COMPLETELY CONTAINED INSIDE."
- store space(2) to whval3
- store space(10) to whval4
- @ 11,3 say "ENTER MOSAIC TYPE (i.e. F, C1, C2): " get whval3 picture "!!"
- @ 12,3 say "ENTER MOSAIC NAME (i.e. 75N351;1): " get whval4 picture "!!!!!!!!!!"
- read
- if whval3 = " " .or. whval4 = " "
- return
- endif
- store whval3 + whval4 to typemidr
- store trim(typemidr) to Xtypemidr
-
- find &Xtypemidr
- if .not. found()
- @ 20,7 SAY "The mosaic type and name you entered cannot be found."
- wait " Press any key to continue."
- return
- endif
- store type to type1
- store midr to midr
- store upperlat to upper
- store lowerlat to lower
- store farleft to left
- store farright to right
-
- clear
- @ 2,7 say type1 + " " + midr
- use names
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < right .and. farright > left
- store 6 to row
- do FEANAME
- if (right > 359.99)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right-360) .and. farright > (left-360)
- do FEANAME
- endif
- if (left < 9.81)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right+360) .and. farright > (left+360)
- do FEANAME
- endif
-
- store 'N' to whval7
- @ 24,5 say "Do you wish to print these results ?: " ;
- get whval7 picture '!'
- read
- if whval7 = 'Y'
- clear
- @ 10,10 say "WAIT, PLEASE."
- set device to print
- @ 5,5 say "Type: "
- @ 5,16 say type1
- @ 6,5 say "MIDR: "
- @ 6,16 say midr
- @ 7,5 say " "
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < right .and. farright > left
- goto top
- disp all FEATURE, NAME to print off
- if (right > 359.99)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right-360) .and. farright > (left-360)
- goto top
- @ prow()+1,5 say " "
- disp all FEATURE, NAME to print off
- endif
- if (left < 9.81)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right+360) .and. farright > (left+360)
- goto top
- @ prow()+1,5 say " "
- disp all FEATURE, NAME to print off
- endif
- eject
- set device to screen
- endif
- RETURN
-
- PROCEDURE FEANAME
- goto top
- @ 4,7 say "FEATURE NAME"
- @ 5,7 say "------- ----"
- do while .not. eof()
- @ row,7 say feature + " " + name
- if row > 21
- @ (row+1),7 say " "
- wait " Press any key to continue."
- clear
- @ 2,7 say type1 + " " + midr
- @ 4,7 say "FEATURE NAME"
- @ 5,7 say "------- ----"
- store 6 to row
- else
- row = row + 1
- endif
- skip
- enddo
- RETURN
-
- PROCEDURE REGION
- use names
- clear
- @ 2, 5 say " "
- ? "THIS OPTION FINDS THE NAMED FEATURES INSIDE A SPECIFIED REGION."
- ? "IT CAN FIND WHETHER A FEATURE YOU HAVE LOCATED HAS A NAME."
- ? "THE REGION CAN BE A POINT (ONE LAT/LONG) OR CAN WRAP PAST 360."
- ?
- ? "ALL NAMED FEATURES WHICH OVERLAP OR LIE INSIDE THE SPECIFIED MOSAIC"
- ? "WILL BE FOUND. SOME FEATURES MAY BE LARGER THAN THE MOSAIC, SO"
- ? "THEY WILL NOT BE COMPLETELY CONTAINED INSIDE."
- store 0 to upper, lower, left, right
- @ 11, 7 say "UPPER LATITUDE (90.0 to -90.0): " get upper picture "###.##"
- @ 12, 7 say "LOWER LATITUDE (90.0 to -90.0): " get lower picture "###.##"
- @ 13, 7 say "LEFT LONGITUDE (0.0 to 360.0): " get left picture "###.##"
- @ 14, 7 say "RIGHT LONGITUDE (0.0 to .....): " get right picture "###.##"
- read
- if upper > 90 .or. upper < -90 .or. lower > 90 .or. lower < -90 ;
- .or. left < 0 .or. left > 360 .or. right < 0 ;
- .or. lower > upper .or. left > right
- @ 23,5 say "Value of latitude/longitude out of range."
- wait " Press any key to continue."
- return
- endif
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < right .and. farright > left
- clear
- store 6 to row
- store " " to type1, midr
- do FEANAME
- if (right > 359.99)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right-360) .and. farright > (left-360)
- do FEANAME
- endif
- if (left < 9.81)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right+360) .and. farright > (left+360)
- do FEANAME
- endif
-
- store 'N' to whval7
- @ 24,5 say "Do you wish to print these results ?: " ;
- get whval7 picture '!'
- read
- if whval7 = 'Y'
- clear
- @ 10,10 say "WAIT, PLEASE."
- set device to print
- @ 5,5 say "Upper Latitude:"
- @ 5,22 say upper
- @ 6,5 say "Lower Latitude:"
- @ 6,22 say lower
- @ 7,5 say "Left Longitude:"
- @ 7,22 say left
- @ 8,5 say "Right Longitude:"
- @ 8,22 say right
- @ 9,5 say " "
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < right .and. farright > left
- goto top
- disp all FEATURE, NAME to print off
- if (right > 359.99)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right-360) .and. farright > (left-360)
- goto top
- @ prow()+1,5 say " "
- disp all FEATURE, NAME to print off
- endif
- if (left < 9.81)
- set filter to lowerlat < upper .and. upperlat > lower ;
- .and. farleft < (right+360) .and. farright > (left+360)
- goto top
- @ prow()+1,5 say " "
- disp all FEATURE, NAME to print off
- endif
- eject
- set device to screen
- endif
- RETURN
-